package com.mecol.library.dao;

import com.mecol.library.entity.Lend;
import com.mecol.library.entity.LendSearch;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

public interface LendDao {
    List<Lend> getAllLendList(LendSearch search);

    Lend getLendById(int ser_num);

    void updateLend(Lend lend);

    void deleteLendById(int ser_num);

    void insertNewLend(@Param("book_id") Long book_id, @Param("user_id") Long user_id,
                       @Param("lend_date") Date lend_date);

    List<Lend> getMyLendList(Long user_id);
}
